import React from 'react';
import {useLocation} from "react-router-dom";

function Detail(props) {
    const {state: {id, title, content}} = useLocation()

    return (
        <div>
            <ul>
                <li>消息编号：{id}</li>
                <li>消息标题：{title}</li>
                <li>消息内容：{content}</li>
            </ul>
        </div>
    );
}

export default Detail;